Analysis of samples